import React, {Component} from 'react'
import { Icon, Button } from 'antd-mobile'

export default class Myheader extends Component {
  constructor (props){
   super(props)
   this.state= {}
}
   render() {
   return <div className="myheader">
            <div className="left">
             <Icon type="left"  onClick={() =>{this.props.leftaction ? this.props.leftaction() : this.props.history.go(-1)}} />
            </div>
            <div className="my_center_title">{this.props.children}</div>
   </div>
   }
}